package hk.mars.controller;

import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;
import org.springframework.web.bind.annotation.RestController;

/**
 * @author Mars(qingke.hk @ gmail.com)
 * @version 0.0.1
 * @date 2018/12/07
 */
@RestController
@RequestMapping("/home")
public class HelloWorldController {
    @RequestMapping("/index")
    public String index() {
        return "Hello Word";
    }

    @RequestMapping(value = "/test", method = {RequestMethod.GET, RequestMethod.POST})
    public String test() {
        return "this is a test";
    }

    @RequestMapping("")
    public String home() {
        return "home";
    }
}
